<%--
  Created by IntelliJ IDEA.
  User: Administrator
  Date: 2021/10/18
  Time: 11:50
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>修改密码界面</title>
</head>
<body bgcolor="#f5f5dc" >
<div style="width:100%;text-align:center">
    <form method="post"   action="/loginServlet?method=toReset"    autocomplete="off">
        旧密码：</label><input type="password" name="oldpassword" id="oldpassword"><br/>
        新密码：</label><input type="password" name="newpassword" id="newpassword"><br/>
        确认密码：</label><input type="password" name="ispassword" id="ispassword"><br/>
        <button type="submit" >确认修改</button>
        <%--    onClick="test()"--%>
        <%--    <button type="submit" onclick='location.href="${ctx}/passwordServlet?operation=toMain"'>返回主页</button>--%>
    </form>
</div>

</body>
<script>
    function test(){
        var f = document.getElementsByTagName("form")[0];
        f.action=f.action+"oldpassword"+document.getElementById("oldpassword").value+
            "newpassword"+document.getElementById("newpassword").value
            +"ispassword"+document.getElementById("ispassword").value;
        alert(f.action);
    }
</script>
</html>
